package com.xunk.equipment.service.zhijia.constant;

/**
 * @ProjectName: HIM
 * @Package: com.xunk.equipment.service.zhijia.constant
 * @ClassName: ZhijiaConstant
 * @Author: luanzhiwei
 * @Description: 智家使用常量
 * @Date: 2021/4/9 9:53
 * @Version: 1.0
 */
public class ZhijiaConstant {
    /**
     * 智家存储redis前缀
     */
    public static final String ZHIJIA_KEY = "ZHIJIA:";
    /**
     * 授权凭证
     */
    public static final String ACCESS_TOKEN = "accessToken";
    /**
     * 刷新凭证
     */
    public static final String REFRESH_TOKEN = "refreshToken";
    /**
     * userid
     */
    public static final String USER_ID = "userId";
    /**
     * accessToken的有效时间（以秒为单位）
     */
    public static final String EXPIRES_IN = "expiresIn";
    /**
     * payload
     */
    public static final String PAYLOAD = "payload";
    /**
     * 智家回调认证码集合
     */
    public static final String CALLBACK_STATE_KEY = ZHIJIA_KEY + "CALLBACK_STATE_KEY:";
    /**
     * 授权凭证redis key
     */
    public static final String ACCESS_TOKEN_KEY = ZHIJIA_KEY + "ACCESS_TOKEN_KEY:";
    /**
     * 刷新凭证redis key
     */
    public static final String REFRESH_TOKEN_KEY = ZHIJIA_KEY + "REFRESH_TOKEN_KEY:";
    /**
     * 智家授权typeid的key
     */
    public static final String TYPE_ID_LIST_KEY = ZHIJIA_KEY + "TYPE_ID_LIST_KEY";
    /**
     * 智家返回的成功码
     */
    public static final String SUCCESS_CODE = "00000";
    /**
     * systemId
     */
    public static final String SYSTEM_ID = "systemId";
    /**
     * apiVersion
     */
    public static final String API_VERSION = "apiVersion";
    /**
     * sign
     */
    public static final String SIGN = "sign";
    /**
     * timestamp
     */
    public static final String TIMESTAMP = "timestamp";
    /**
     * 刷新设备列表接口
     */
    public static final String URL_ALL_DEVICE_INFO = "/dcs/third-party-cloud/add/user/third-party/device";
    /**
     * 我的设备列表接口
     * 查询我所有的设备,包含我的设备,个人分享给我的设备,家庭分享给我的设备
     */
    public static final String URL_MY_ALL_DEVICE = "/uds/v1/protected/deviceinfos";
    /**
     * 查询拓扑网络关系接口
     * 根据DeviceId和token查询设备拓扑关系，如果用户对该设备有权限继续查询，反之返回错误码(1200001: 当前用户与该设备不匹配);
     */
    public static final String URL_TOPOLOGICAL = "/dcs/device-service-2c/get/device/topological/relation";
    /**
     * 查询设备详情接口
     */
    public static final String URL_DEVICE_DETAIL = "/dcs/third-party-cloud/get/device/detail";
    /**
     * 查询设备状态接口
     */
    public static final String URL_DEVICE_STATUS = "/dcs/third-party-cloud/get/device/status";
    /**
     * 设备控制接口
     */
    public static final String URL_DEVICE_CMD = "/dcs/third-party-cloud/update/device/cmd";
    /**
     * 查询第三方开通预授权的型号列表
     */
    public static final String URL_DEVICE_MODELS = "/dcs/third-party-cloud/get/third-party/device-models";
    /**
     * 设备id
     */
    public static final String DEVICE_ID = "deviceId";
    /**
     * 过滤参数；查询结果一定返回shadowBaseInfo部分；通过过滤参数控制返回其他部分；等于1时，其他只返回reported部分；等于2时，其他只返回desired部分；等于0时，其他部分全部返回；默认值为0；
     */
    public static final String PART = "part";

    public static final String RET_CODE = "retCode";

    public static final String RET_INFO = "retInfo";

    public static final String DEVICE_SN_DEPT_ID_HOME_ID = ZHIJIA_KEY + "DEVICE_SN_DEPT_ID_HOME_ID";
}
